﻿using System.Collections.Generic;
using System.Linq.Expressions;

namespace Uber.Core.Repository
{
    using System;
    using Model;
    
    public interface IRepo<T> where T : Entity
    {
        T Get(long id);
        IEnumerable<T> Where(Expression<Func<T, bool>> predicate);
        void Add(T o);
        void Save();
        void Delete(long id);
        T Create();
        void Remove(T o);
    }

    public interface IUniRepo
    {
        void Add<T>(T o) where T : Entity;
        void Save();
        T Get<T>(long id) where T : Entity;
        IEnumerable<T> GetAll<T>() where T : Entity;
        IEnumerable<T> Where<T>(Expression<Func<T, bool>> predicate) where T: Entity;
        T Create<T>() where T : class;
    }

    public interface IAccountRepo
    {
       
    }
}